from django.db import models

# Create your models here.

SCHOOL_CHIOCES = [
    (1, "清华大学"),
    (2, "北京大学"),
    (3, "浙江大学"),
    (4, "复旦大学"),
]

class Student(models.Model):
    created = models.DateTimeField(auto_now_add=True)
    name = models.CharField(max_length=30)
    sno = models.CharField(max_length=20)
    school = models.CharField(choices=SCHOOL_CHIOCES, default=1,
            max_length=20)

    class Meta:
        ordering = ('created',)
